<%--
  Created by IntelliJ IDEA.
  User: 凡人
  Date: 2021/11/29
  Time: 10:10
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <!--视口 自适应-->
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>title</title>
    <link href="${pageContext.request.contextPath}/static/css/bootstrap4.css" rel="stylesheet">
    <script src="${pageContext.request.contextPath}/static/js/jquery-3.2.1.js" rel="script"></script>
    <script src="${pageContext.request.contextPath}/static/js/bootstrap-treeview.js" rel="stylesheet"></script>
    <script src="${pageContext.request.contextPath}/static/js/bootstrap.js" rel="script"></script>
    <script src="${pageContext.request.contextPath}/static/My97DatePicker/WdatePicker.js" rel="script"></script>

</head>
<body>
<div class="row">
    <div class="col-2">
        <div class="list-group" id="list-tab" role="tablist">

        </div>
    </div>
    <div class="col-10">
        <div class="tab-content" id="nav-tabContent">

        </div>
    </div>
</div>
</body>
<script>
    $(function(){
        $.post("getTree",function(obj){
            $("#list-tab").treeview({
                data:obj,
                levels: 5,
                onNodeSelected: function(b,a){
                    if(a.href!=null && a.href!=''){
                        $("#nav-tabContent").load(a.href);
                    }
                }
            })
        })
    })
</script>
</html>
